// 语言适配器管理器
import cppAdapter from './cpp-adapter.js';
import csharpAdapter from './csharp-adapter.js';
import javaAdapter from './java-adapter.js';

export const LanguageAdapter = {
  cpp: cppAdapter,
  csharp: csharpAdapter,
  java: javaAdapter
};

export function getAdapter(language) {
  const adapter = LanguageAdapter[language];
  if (!adapter) {
    throw new Error(`不支持的语言: ${language}`);
  }
  return adapter;
}